<?php

namespace AppBundle\Services;

/**
 *
 * 订单数据处理
 * @author  coffey  <coffey@nligo.com>
 * @time    2017/2/21
 */
class HandleOrderData extends ContainerAware
{
    public function createData($str = '')
    {
        if (!empty($str))
        {
        }
    }

    /**
     * @author  coffey  <coffey@nligo.com>
     *
     * 将字符串分割为数组
     * @param $string
     * @param int $len
     * @return array
     */
    private function mbStrSplit ($string, $len=1) {
        $start = 0;
        $strlen = mb_strlen($string);
        while ($strlen) {
            $array[] = mb_substr($string,$start,$len,"utf8");
            $string = mb_substr($string, $len, $strlen,"utf8");
            $strlen = mb_strlen($string);
        }
        return $array;
    }
}